<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>约健</title>
    {load href="__STATIC__/assets/css/bootstrap.css,__STATIC__/assets/css/font-awesome.css,__STATIC__/assets/css/basic.css"/}
    <!--BOOTSTRAP STYLES-->
    <!--<link href="assets/css/bootstrap.css" rel="stylesheet" />-->
    <!--&lt;!&ndash; FONTAWESOME STYLES&ndash;&gt;-->
    <!--<link href="assets/css/font-awesome.css" rel="stylesheet" />-->
    <!--&lt;!&ndash;CUSTOM BASIC STYLES&ndash;&gt;-->
    <!--<link href="assets/css/basic.css" rel="stylesheet" />-->
    <!--&lt;!&ndash;CUSTOM MAIN STYLES&ndash;&gt;-->
    <!--<link href="assets/css/custom.css" rel="stylesheet" />-->
    <!--&lt;!&ndash; GOOGLE FONTS&ndash;&gt;-->
    <!--<link href='https://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css' />-->
    <style>
        #clubmgerlist img
        {
            width: 100px;
            height: 100px;
        }
    </style>
</head>
<body>
<div id="wrapper">
    {include file="common/header"}
    <!-- /. NAV TOP  -->
    {include file="common/menu"}

    <!-- /. NAV SIDE  -->
    <div id="page-wrapper">
        <div id="page-inner">

            <div class="row">
                <div class="col-md-12">
                    <h1 class="page-head-line">精选活动列表</h1>
                </div>
            </div>
            <div class="row ">

                <br />

            </div>

            <div class="col-md-12">
                <!--    Context Classes  -->
                <div class="panel panel-default">

                    <div class="panel-heading" style="overflow: hidden">
                        <button  class="btn btn-default" style="float: left" onclick="javascript:window.location.href='{:url("Activity/addActivity")}'"><i class="glyphicon glyphicon-plus"></i>添加</button>
                        <div class="form-group input-group col-md-6 " style="float: left">
                            <input type="text" class="form-control" placeholder="Enter Keywords" />
                            <span class="input-group-btn">
                       <a class="btn btn-primary" href="index.html">
                        <i class="fa fa-gear fa-spin"></i>搜索
                       </a>
                       </span>
                        </div>

                    </div>

                    <div class="panel-body">
                        <div class="table-responsive">
                            <table class="table" id="clubmgerlist">
                                <thead>
                                <tr>
                                    <th>#</th>
                                    <th>活动名称</th>
                                    <th>活动地址</th>
                                    <th>活动时间</th>
                                    <th>活动收费</th>
                                    <th>已报名人数</th>
                                    <th>咨询热线</th>
                                    <th>活动海报</th>
                                    <th>活动简介</th>
                                    <th>操作</th>
                                </tr>
                                </thead>
                                <tbody>
                                {volist name="activityList" id="vo"}
                                <tr class="success">
                                    <td>{$key+1}</td>
                                    <td>{$vo.selectact_name}/td>
                                    <td>{$vo.selectact_address}</td>
                                    <td>{$vo.selectact_time}</td>
                                    <td>{$vo.selectact_price}元/人</td>
                                    <td>{$vo.selectact_count}</td>
                                    <td>{$vo.selectact_phone}</td>
                                    <td><img src="__STATIC__/img/activity/{$vo.selectact_poster}" alt=""></td>
                                    <td>{$vo.selectact_intro}</td>
                                    <td>
                                        <button type="button" class="btn btn-default" onclick='javascript:window.location.href="{:url('Activity/updateact',['selectact_id'=>$vo.selectact_id])}" '>修改</button>
                                        <button type="button" class="btn btn-danger iiu" idvalue="{$vo.selectact_id}">删除</button>
                                    </td>
                                </tr>
                                {/volist}


                                </tbody>
                            </table>
                        </div>
                    </div>
                </div>
                <!--  end  Context Classes  -->
            </div>
        </div>
        <!-- /. ROW  -->

    </div>
    <!-- /. PAGE INNER  -->
    <!--模态框-->
    <div class="modal fade" tabindex="-1" id="myModal" role="dialog">
        <div class="modal-dialog" role="document">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                    <h4 class="modal-title">提示</h4>
                </div>
                <div class="modal-body">
                    <p>确认删除该条记录吗？&hellip;</p>
                </div>
                <div class="modal-footer">
                    <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                    <button type="button"  class="btn btn-primary confiredele">确认</button>
                </div>
            </div><!-- /.modal-content -->
        </div><!-- /.modal-dialog -->
    </div><!-- /.modal -->
</div>
<!-- /. PAGE WRAPPER  -->

<!-- /. WRAPPER  -->
{include file="common/footer"}
<!-- /. FOOTER  -->
<!-- SCRIPTS -AT THE BOTOM TO REDUCE THE LOAD TIME-->
<!-- JQUERY SCRIPTS -->
{load href="__STATIC__/assets/js/jquery-1.10.2.js,__STATIC__/assets/js/bootstrap.js,__STATIC__/assets/js/jquery.metisMenu.js,__STATIC__/assets/js/custom.js" /}

<!--<script src="assets/js/jquery-1.10.2.js"></script>-->
<!--&lt;!&ndash; BOOTSTRAP SCRIPTS &ndash;&gt;-->
<!--<script src="assets/js/bootstrap.js"></script>-->
<!--&lt;!&ndash; METISMENU SCRIPTS &ndash;&gt;-->
<!--<script src="assets/js/jquery.metisMenu.js"></script>-->
<!--&lt;!&ndash; CUSTOM SCRIPTS &ndash;&gt;-->
<!--<script src="assets/js/custom.js"></script>-->
<script>
    $(function () {


        $(".iiu").click(function () {
            $("#myModal").modal('show');
            var id = $(this).attr("idvalue");
            $(".confiredele").click(function () {

                $.post("{:url('Activity/delete')}",{activity_id:id},function (result) {
                    if (result.success==1)
                    {
                        alert('删除成功');
                        window.location.reload();
                    }
                    elsel
                    {
                        alert('删除失败')
                    }
                })



            });
        });



    });


</script>

</body>
</html>

